#include <iostream>
#include <clocale>
#include <vector>
#include <thread>
#include "Player.h"
#include "Game.h"
#include "Console.h"

#define AREA 10
using namespace std;
using namespace Course;

int main()
{
        setlocale(LC_ALL, "swedish");

        deque<char> Player1Queue;
        deque<char> Player2Queue;
        deque<Position> GameQueue;
        Player p1('w', 'a', 's', 'd', '1', AREA-AREA, AREA-AREA, AREA, Player1Queue, GameQueue);
        Player p2(72, 75, 80, 77, '2', AREA-1, AREA-1, AREA, Player2Queue, GameQueue);
        Game game(AREA, Player1Queue, Player2Queue, GameQueue);

        thread t_game(game);
        thread t_p1(p1);
        thread t_p2(p2);

        t_game.join();
        t_p1.join();
        t_p2.join();

        cout << endl;
        system("PAUSE");
        return 0;
}